import request from '@/utils/request'

// 律所信息
export function getOffices(params) {
  return request({
    url: '/office/office_info/',
    method: 'GET',
    params,
  })
}

export function addOffice(officeInfo) {
  return request({
    url: '/office/office_info/',
    method: 'POST',
    data: officeInfo
  })
}

export function updateOffice(officeInfo) {
  return request({
    url: `/office/office_info/${officeInfo.id}/`,
    method: 'PATCH',
    data: officeInfo
  })
}

export function delOffice(office_id) {
  return request({
    url: `/office/office_info/${office_id}/`,
    method: 'DELETE',
  })
}

export function officeOne() {
  return request({
    url: '/office/office_one/',
    method: 'GET',
  })
}